import request from '../request/request';

interface CompanyState {
        Id : number
        Createtime: string
        Message : string
}

export default class CompanyStateApi{
     // 查询
     static getList = () => {
        return request({
            url: '/v1/company_state',
            // params: {current, size},
            method: 'GET',
        })
    }

    // 查询一个
    static getOne = (id:string) =>{
        return request({
            url: '/v1/company_state/'+id,
            method: 'GET',
        })
    }

    // 修改
    static update=(data:CompanyState)=>{
        return request({
            url: '/v1/company_state',
            data: data,
            method: 'PUT',
        })
    }

    // 添加
    static add=(data:CompanyState)=>{
        return request({
            url: '/v1/company_state',
            data: data,
            method: 'POST',
        })
    }

    // 删除
    static delete=(id:string)=>{
        return request({
            url: '/v1/company_state/'+id,
            method: 'DELETE',
        })
    }
}